<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<%@ page contentType="text/html; charset=UTF-8" pageEncoding="utf-8"%>
<%@ include file="/common/init.jsp"%>
<html> 
<head> 
<link href="<c:url value='/resources/css/zTreeStyle/zTreeStyle.css'/>" type="text/css" rel="stylesheet"/>
<script type="text/javascript" src="<c:url value='/resources/js/jquery-1.7.2.min.js'/>"></script>
<script type="text/javascript" src="<c:url value='/resources/js/jquery.ztree.all-3.5.min.js'/>"></script>
<link href="<c:url value='/admin/css/custom.css'/>" rel="stylesheet" type="text/css" />
<link href="<c:url value='/admin/css/style.css'/>" rel="stylesheet" type="text/css" />
<title> </title> 
  <style> 
/*基本信息*/  
body {font:12px Tahoma;margin:0px;text-align:center;background:#DFE5E7;}  
a:link,a:visited {font-size:12px;text-decoration:none;}  a:hover{}  
.divGlobal,.DivTop,.DivBottom{min-width: 760px;width: expression_r(document.body.clientWidth < 760? "760px": "100%" );width:100%;margin：0;} 
.divGlobal{} 
.DivTop,.DivBottom,.DivMainLeft,.DivMainRight {border:0px solid #ff0000;} 
.DivBottom {background:#d2e3ff;clear: both;} 
.DivMainLeft{float:left;} 
.DivMainRight{margin-left:210px;} 
.DivFiexWidth{width:200px;} 
.DivMainRightChildTop{height:20px;} 
.DivMainRightChild{} 
.clear{clear: both;} 

 /*菜单格式*/
#menu {padding:20px 20px 0 0}  

#topFrame { background: url(<c:url value='/resources/images/banner_bg.jpg'/>) left top no-repeat; height:65px;background-color:#5EAAE6}

.gridView {
	border-right: #bad6ec 1px; border-top: #bad6ec 1px; border-left: #bad6ec 1px; color: #566984; border-bottom: #bad6ec 1px; font-family: Courier New
}
.gridViewHeader {
	border-right: #bad6ec 1px solid; border-top: #bad6ec 1px solid; background-image: url(../images/bg_th.gif); border-left: #bad6ec 1px solid; line-height: 27px; border-bottom: #bad6ec 1px solid
}
.gridViewItem {
	border-right: #bad6ec 1px solid; border-top: #bad6ec 1px solid; border-left: #bad6ec 1px solid; line-height: 32px; border-bottom: #bad6ec 1px solid; text-align: center
}
</style>

<script type="text/javascript">
<!--
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}
function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
//-->
</script>
 
</head> 

 <body> 
<div class="DivTop" id="topFrame">
	
</div>
<div id="topwelcome">
<div id="left">系统管理员: ${admin.userAccount }</div>
<div id="time"> 
  <script language=JavaScript>
today=new Date();
function initArray(){
this.length=initArray.arguments.length
for(var i=0;i<this.length;i++)
this[i+1]=initArray.arguments[i]  }
var d=new initArray(
"星期日",
"星期一",
"星期二",
"星期三",
"星期四",
"星期五",
"星期六");
document.write(
today.getYear(),"年",
today.getMonth()+1,"月",
today.getDate(),"日   ",
d[today.getDay()+1],
"</font>" );
</script>
</div>
<div id="right"><a href="javascript:void(0);" onclick="tomodify('${admin.userId}')" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Image3','','<c:url value="/admin/images/button_modify_1.gif"/>',1)"><img src="images/button_modify.gif" name="Image3" width="89" height="21" border="0" id="Image3" /></a><a href="logout.action" target="_parent" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Image2','','images/button_out_1.gif',1)"><img src="images/button_out.gif" name="Image2" width="78" height="21" border="0" id="Image2" /></a><a href="logout.action" target="_parent" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Image4','','images/button_relogin_1.gif',1)"><img src="images/button_relogin.gif" name="Image4" width="95" height="21" border="0" id="Image4" /></a></div>
</div>
  <div class="divGlobal">
   <div class="DivMainLeft"> 
    <div class="DivFiexWidth" style="background-color: #D2E3FF"> 
		<ul id="menu" class="ztree" style="margin-left: 20px;"></ul>
    </div> 
   </div> 
 
  <div class="DivMainRight"> 
    <!-- <div class="DivMainRightChildTop" style="float:left;padding:10px 5px; width: 98%;"> 
    <marquee id="scrollArea" height="20px" width="100px" scrollamount="1" 
	scrolldelay="50" direction="left" onMouseOver="scrollArea.stop()" onMouseOut="scrollArea.start()">
	欢迎您
	</marquee>

		<div id="menu">    
			i1111111
		</div>    
		<div id="banner">  22222222 </div>
    </div> -->
    <div class="DivMainRightChild" style="float:left;padding:1px 1px; width: 99%; height:700px;overflow: auto;" > 
		<iframe id="frame1" name="frame1" frameborder="0" src="receivemsglist.action"  width="100%" height="99%">
		</iframe>
   </div> 
   </div> 
 </div> 

<div class="DivBottom" style="height: 37px;"> 
	<div id="copytext"></div>
</div>

 </body> 
</html>
<script type="text/javascript">
	var zTreeObj;
	var treeNodes = ${menudate};
	var setting = {
		    data: {
		        simpleData: {
		        	enable: true,
					idKey: "id",
					pIdKey: "pId",
					rootPId: 0
		        }
		    },
		    callback: {
		    	onClick: selectNode
		    }
		};
	function selectNode(event, treeId, treeNode){
	    var id = treeNode.id ;
	    var url = treeNode.tourl;
	   // alert("${ctx}/"+url);
	    if('#' == url || !url){
	    	return;
	    }
		frame1.location.href = "${ctx}/"+url ; 
	}
	
	$(document).ready(function(){
		zTreeObj = $.fn.zTree.init($("#menu"), setting, treeNodes);
		zTreeObj.expandAll(true);
	});
	
	function tomodify(userId){
		frame1.location.href="${ctx}/admin/toupdatepwd.action?userId="+userId+"&type=1";
	}
	
</script>